<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script>
        var ad_score = Number(prompt("请输入你的高数成绩"));
        var English_score = Number(prompt("请输入你的英语成绩"));
        var c_score = Number(prompt("请输入你的C语言成绩"));
        function gpa(a,b,c){
            var av_gpa = Number((a+b+c)/3)
            alert("你的平均成绩："+av_gpa);
            total_gpa = parseInt(av_gpa/10);
            alert("绩点等级为：")
            switch(total_gpa){
                case 10:
                case 9:  
                    alert("优秀");
                    break;
                case 8:
                    alert("良好");
                    break;
                case 7:
                    alert("中等");
                    break;
                case 6:
                    alert("及格");
                    break;
                default:
                    alert("不及格");
            }
             
        }
        gpa(ad_score,English_score,c_score);
    </script>
</head>
<body>
    
</body>
</html>